package com.last.controller;

import com.last.bean.SearchBean;
import com.last.entity.HouseName;
import com.last.entity.Result;
import com.last.entity.RoomInfo;
import com.last.service.IHousingDetailService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/housing")
public class HousingDetailController {
    @Autowired
    private IHousingDetailService housingDetailService;

    @RequestMapping("/getHousingDetail")
    public Result getHousingDetail(Integer homeId){
        Result result = housingDetailService.getHouseDetailInfo(homeId);
        return result;
    }

    @RequestMapping("/roomInfoList")
    public Result roomInfoList(Integer homeId){
        Result result = housingDetailService.roomInfoList(homeId);
        return result;
    }

}
